FROM centos:6

RUN yum install -y --nogpgcheck php-5.2.13 && yum clean all
RUN sed -e 's/127.0.0.1:9000/9001/' \
        -e '/allowed_clients/d' \
		-e '/daemonize/s/yes/no/' \
        -e '/catch_workers_output/s/^;//' \
        -e '/error_log/d' \
        -i /usr/local/php/etc/php-fpm.conf

EXPOSE 9000

ENTRYPOINT /usr/local/php/bin/php-cgi --fpm